import sys
import json


sys.path.append(r'./')


import codesecurity.feature.tree_sitter_adapter as tree_sitter_adapter
import codesecurity.feature.objects as data_objects

import tree_sitter

parser=tree_sitter_adapter.create_parser('js')


test_file='test_data/sample.js'
try:
    content=data_objects.feature_api.read_bytes(test_file)
    root=parser.parse(content)
    for e in root.walk():
        print(e)
except:
    pass
